< previous page page_61 next page >

Page 61
Private Sub List1_Click()
   Dim thiskey As String
   Dim thisvalue As Variant
   Dim currentkey As clsKeyValues
   thiskey = List1.Text

   For Each currentkey In GlobalKeyCollection
      If currentkey.KeyName = thiskey Then
         List2.Clear
         For Each thisvalue In currentkey.ValueNames
            List2.AddItem thisvalue
         Next
      End If
   Next currentkey

End Sub
Results
Naturally, the sample code shown here does not work. It wouldn't be much of a puzzle if it did. Your challenge is to fix the program.

 
< previous page page_61 next page >